import os
import time
import cv2
import numpy as np
import pandas as pd
from keras.applications.efficientnet import EfficientNetB0, preprocess_input
from keras.preprocessing.image import ImageDataGenerator
from keras.models import Model
from keras.layers import Dense, Flatten, BatchNormalization, Dropout, GlobalAveragePooling2D
from sklearn.metrics import classification_report, roc_curve, auc
import matplotlib.pyplot as plt
from keras.utils import to_categorical
from keras.optimizers import Adam
from keras.losses import categorical_crossentropy
from keras.callbacks import EarlyStopping, ModelCheckpoint, ReduceLROnPlateau

# Load EfficientNetB0 model
base_model = EfficientNetB0(weights='imagenet', include_top=False, input_shape=(224, 224, 3))
x = base_model.output
x = GlobalAveragePooling2D()(x)  # Use GlobalAveragePooling instead of Flatten
x = BatchNormalization()(x)
x = Dense(512, activation='relu', kernel_regularizer='l2')(x)  # Increase the number of units
x = Dropout(0.5)(x)
output = Dense(2, activation='softmax')(x)  # new output layer
model = Model(inputs=base_model.input, outputs=output)

# Freeze the layers except the last few layers
for layer in base_model.layers[:-10]:
    layer.trainable = False

# Compile the model
model.compile(optimizer=Adam(learning_rate=0.0001), loss=categorical_crossentropy, metrics=['accuracy'])  # Adjust learning rate

# Print the model summary
model.summary()

# Function to detect and crop chest area
def detect_and_crop_chest(image):
    gray = cv2.cvtColor(image, cv2.COLOR_BGR2GRAY)
    chest_cascade = cv2.CascadeClassifier(cv2.data.haarcascades + 'haarcascade_fullbody.xml')
    chests = chest_cascade.detectMultiScale(gray, 1.1, 4)
    for (x, y, w, h) in chests:
        return image[y:y+h, x:x+w]
    return image  # return original image if no chest is detected

# Load and preprocess images
def load_images_from_folder(folder):
    images = []
    for filename in os.listdir(folder):
        img = cv2.imread(os.path.join(folder, filename))
        if img is not None:
            img = detect_and_crop_chest(img)
            img = cv2.resize(img, (224, 224))
            images.append(img)
    return images

# Load training images
train_dir = 'D:\\kaggle\\final\\data1\\train'
cancer_train_dir = os.path.join(train_dir, 'cancer')
normal_train_dir = os.path.join(train_dir, 'normal')

cancer_train_images = load_images_from_folder(cancer_train_dir)
normal_train_images = load_images_from_folder(normal_train_dir)

# Load testing images
test_dir = 'D:\\kaggle\\final\\data1\\test'
cancer_test_dir = os.path.join(test_dir, 'cancer')
normal_test_dir = os.path.join(test_dir, 'normal')

cancer_test_images = load_images_from_folder(cancer_test_dir)
normal_test_images = load_images_from_folder(normal_test_dir)

# Create labels
cancer_train_labels = [1 for _ in range(len(cancer_train_images))]
normal_train_labels = [0 for _ in range(len(normal_train_images))]

cancer_test_labels = [1 for _ in range(len(cancer_test_images))]
normal_test_labels = [0 for _ in range(len(normal_test_images))]

# Combine data
X_train = np.array(cancer_train_images + normal_train_images)
y_train = np.array(cancer_train_labels + normal_train_labels)

X_test = np.array(cancer_test_images + normal_test_images)
y_test = np.array(cancer_test_labels + normal_test_labels)

# Preprocess images
X_train = preprocess_input(X_train)
X_test = preprocess_input(X_test)

# Convert labels to categorical
y_train = to_categorical(y_train, num_classes=2)
y_test = to_categorical(y_test, num_classes=2)

# Data augmentation
datagen = ImageDataGenerator(
    rotation_range=40,
    width_shift_range=0.4,
    height_shift_range=0.4,
    shear_range=0.4,
    zoom_range=0.4,
    horizontal_flip=True,
    fill_mode='nearest'
)

# Callbacks
checkpoint_dir = './checkpoints'
os.makedirs(checkpoint_dir, exist_ok=True)

checkpoint = ModelCheckpoint(filepath=os.path.join(checkpoint_dir, 'chest_CT_SCAN-EfficientNetB0.h5'),
                             monitor='val_loss',
                             mode='auto',
                             save_best_only=True,
                             save_weights_only=True)  # Save only the weights
early_stopping = EarlyStopping(verbose=1, patience=10)
reduce_lr = ReduceLROnPlateau(monitor='val_loss', factor=0.2, patience=5, min_lr=0.00001)

# Train model
start_time = time.time()
history = model.fit(datagen.flow(X_train, y_train, batch_size=32), epochs=100, validation_data=(X_test, y_test),
                    callbacks=[checkpoint, early_stopping, reduce_lr])
end_time = time.time()

# Predict on test set
y_pred = model.predict(X_test)

# Convert predictions to labels
y_pred_labels = np.argmax(y_pred, axis=1)
y_test_labels = np.argmax(y_test, axis=1)

# Print classification report
print(classification_report(y_test_labels, y_pred_labels))

# Calculate and plot ROC curve and AUC
fpr, tpr, _ = roc_curve(y_test_labels, y_pred_labels)
roc_auc = auc(fpr, tpr)
plt.figure()
plt.plot(fpr, tpr, label='ROC curve (area = %0.2f)' % roc_auc)
plt.plot([0, 1], [0, 1], 'k--')
plt.xlim([0.0, 1.0])
plt.ylim([0.0, 1.05])
plt.xlabel('False Positive Rate')
plt.ylabel('True Positive Rate')
plt.title('Receiver Operating Characteristic')
plt.legend(loc="lower right")
plt.show()

# Print program running time
print(f'Program running time: {end_time - start_time}')


'''
epoch=50
Model: "model_7"
__________________________________________________________________________________________________
 Layer (type)                   Output Shape         Param #     Connected to                     
==================================================================================================
 input_11 (InputLayer)          [(None, 224, 224, 3  0           []                               
                                )]                                                                
                                                                                                  
 rescaling_4 (Rescaling)        (None, 224, 224, 3)  0           ['input_11[0][0]']               
                                                                                                  
 normalization_2 (Normalization  (None, 224, 224, 3)  7          ['rescaling_4[0][0]']            
 )                                                                                                
                                                                                                  
 rescaling_5 (Rescaling)        (None, 224, 224, 3)  0           ['normalization_2[0][0]']        
                                                                                                  
 stem_conv_pad (ZeroPadding2D)  (None, 225, 225, 3)  0           ['rescaling_5[0][0]']            
                                                                                                  
 stem_conv (Conv2D)             (None, 112, 112, 32  864         ['stem_conv_pad[0][0]']          
                                )                                                                 
                                                                                                  
 stem_bn (BatchNormalization)   (None, 112, 112, 32  128         ['stem_conv[0][0]']              
                                )                                                                 
                                                                                                  
 stem_activation (Activation)   (None, 112, 112, 32  0           ['stem_bn[0][0]']                
                                )                                                                 
                                                                                                  
 block1a_dwconv (DepthwiseConv2  (None, 112, 112, 32  288        ['stem_activation[0][0]']        
 D)                             )                                                                 
                                                                                                  
 block1a_bn (BatchNormalization  (None, 112, 112, 32  128        ['block1a_dwconv[0][0]']         
 )                              )                                                                 
                                                                                                  
 block1a_activation (Activation  (None, 112, 112, 32  0          ['block1a_bn[0][0]']             
 )                              )                                                                 
                                                                                                  
 block1a_se_squeeze (GlobalAver  (None, 32)          0           ['block1a_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block1a_se_reshape (Reshape)   (None, 1, 1, 32)     0           ['block1a_se_squeeze[0][0]']     
                                                                                                  
 block1a_se_reduce (Conv2D)     (None, 1, 1, 8)      264         ['block1a_se_reshape[0][0]']     
                                                                                                  
 block1a_se_expand (Conv2D)     (None, 1, 1, 32)     288         ['block1a_se_reduce[0][0]']      
                                                                                                  
 block1a_se_excite (Multiply)   (None, 112, 112, 32  0           ['block1a_activation[0][0]',     
                                )                                 'block1a_se_expand[0][0]']      
                                                                                                  
 block1a_project_conv (Conv2D)  (None, 112, 112, 16  512         ['block1a_se_excite[0][0]']      
                                )                                                                 
                                                                                                  
 block1a_project_bn (BatchNorma  (None, 112, 112, 16  64         ['block1a_project_conv[0][0]']   
 lization)                      )                                                                 
                                                                                                  
 block2a_expand_conv (Conv2D)   (None, 112, 112, 96  1536        ['block1a_project_bn[0][0]']     
                                )                                                                 
                                                                                                  
 block2a_expand_bn (BatchNormal  (None, 112, 112, 96  384        ['block2a_expand_conv[0][0]']    
 ization)                       )                                                                 
                                                                                                  
 block2a_expand_activation (Act  (None, 112, 112, 96  0          ['block2a_expand_bn[0][0]']      
 ivation)                       )                                                                 
                                                                                                  
 block2a_dwconv_pad (ZeroPaddin  (None, 113, 113, 96  0          ['block2a_expand_activation[0][0]
 g2D)                           )                                ']                               
                                                                                                  
 block2a_dwconv (DepthwiseConv2  (None, 56, 56, 96)  864         ['block2a_dwconv_pad[0][0]']     
 D)                                                                                               
                                                                                                  
 block2a_bn (BatchNormalization  (None, 56, 56, 96)  384         ['block2a_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block2a_activation (Activation  (None, 56, 56, 96)  0           ['block2a_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block2a_se_squeeze (GlobalAver  (None, 96)          0           ['block2a_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block2a_se_reshape (Reshape)   (None, 1, 1, 96)     0           ['block2a_se_squeeze[0][0]']     
                                                                                                  
 block2a_se_reduce (Conv2D)     (None, 1, 1, 4)      388         ['block2a_se_reshape[0][0]']     
                                                                                                  
 block2a_se_expand (Conv2D)     (None, 1, 1, 96)     480         ['block2a_se_reduce[0][0]']      
                                                                                                  
 block2a_se_excite (Multiply)   (None, 56, 56, 96)   0           ['block2a_activation[0][0]',     
                                                                  'block2a_se_expand[0][0]']      
                                                                                                  
 block2a_project_conv (Conv2D)  (None, 56, 56, 24)   2304        ['block2a_se_excite[0][0]']      
                                                                                                  
 block2a_project_bn (BatchNorma  (None, 56, 56, 24)  96          ['block2a_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block2b_expand_conv (Conv2D)   (None, 56, 56, 144)  3456        ['block2a_project_bn[0][0]']     
                                                                                                  
 block2b_expand_bn (BatchNormal  (None, 56, 56, 144)  576        ['block2b_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block2b_expand_activation (Act  (None, 56, 56, 144)  0          ['block2b_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block2b_dwconv (DepthwiseConv2  (None, 56, 56, 144)  1296       ['block2b_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block2b_bn (BatchNormalization  (None, 56, 56, 144)  576        ['block2b_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block2b_activation (Activation  (None, 56, 56, 144)  0          ['block2b_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block2b_se_squeeze (GlobalAver  (None, 144)         0           ['block2b_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block2b_se_reshape (Reshape)   (None, 1, 1, 144)    0           ['block2b_se_squeeze[0][0]']     
                                                                                                  
 block2b_se_reduce (Conv2D)     (None, 1, 1, 6)      870         ['block2b_se_reshape[0][0]']     
                                                                                                  
 block2b_se_expand (Conv2D)     (None, 1, 1, 144)    1008        ['block2b_se_reduce[0][0]']      
                                                                                                  
 block2b_se_excite (Multiply)   (None, 56, 56, 144)  0           ['block2b_activation[0][0]',     
                                                                  'block2b_se_expand[0][0]']      
                                                                                                  
 block2b_project_conv (Conv2D)  (None, 56, 56, 24)   3456        ['block2b_se_excite[0][0]']      
                                                                                                  
 block2b_project_bn (BatchNorma  (None, 56, 56, 24)  96          ['block2b_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block2b_drop (Dropout)         (None, 56, 56, 24)   0           ['block2b_project_bn[0][0]']     
                                                                                                  
 block2b_add (Add)              (None, 56, 56, 24)   0           ['block2b_drop[0][0]',           
                                                                  'block2a_project_bn[0][0]']     
                                                                                                  
 block3a_expand_conv (Conv2D)   (None, 56, 56, 144)  3456        ['block2b_add[0][0]']            
                                                                                                  
 block3a_expand_bn (BatchNormal  (None, 56, 56, 144)  576        ['block3a_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block3a_expand_activation (Act  (None, 56, 56, 144)  0          ['block3a_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block3a_dwconv_pad (ZeroPaddin  (None, 59, 59, 144)  0          ['block3a_expand_activation[0][0]
 g2D)                                                            ']                               
                                                                                                  
 block3a_dwconv (DepthwiseConv2  (None, 28, 28, 144)  3600       ['block3a_dwconv_pad[0][0]']     
 D)                                                                                               
                                                                                                  
 block3a_bn (BatchNormalization  (None, 28, 28, 144)  576        ['block3a_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block3a_activation (Activation  (None, 28, 28, 144)  0          ['block3a_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block3a_se_squeeze (GlobalAver  (None, 144)         0           ['block3a_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block3a_se_reshape (Reshape)   (None, 1, 1, 144)    0           ['block3a_se_squeeze[0][0]']     
                                                                                                  
 block3a_se_reduce (Conv2D)     (None, 1, 1, 6)      870         ['block3a_se_reshape[0][0]']     
                                                                                                  
 block3a_se_expand (Conv2D)     (None, 1, 1, 144)    1008        ['block3a_se_reduce[0][0]']      
                                                                                                  
 block3a_se_excite (Multiply)   (None, 28, 28, 144)  0           ['block3a_activation[0][0]',     
                                                                  'block3a_se_expand[0][0]']      
                                                                                                  
 block3a_project_conv (Conv2D)  (None, 28, 28, 40)   5760        ['block3a_se_excite[0][0]']      
                                                                                                  
 block3a_project_bn (BatchNorma  (None, 28, 28, 40)  160         ['block3a_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block3b_expand_conv (Conv2D)   (None, 28, 28, 240)  9600        ['block3a_project_bn[0][0]']     
                                                                                                  
 block3b_expand_bn (BatchNormal  (None, 28, 28, 240)  960        ['block3b_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block3b_expand_activation (Act  (None, 28, 28, 240)  0          ['block3b_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block3b_dwconv (DepthwiseConv2  (None, 28, 28, 240)  6000       ['block3b_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block3b_bn (BatchNormalization  (None, 28, 28, 240)  960        ['block3b_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block3b_activation (Activation  (None, 28, 28, 240)  0          ['block3b_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block3b_se_squeeze (GlobalAver  (None, 240)         0           ['block3b_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block3b_se_reshape (Reshape)   (None, 1, 1, 240)    0           ['block3b_se_squeeze[0][0]']     
                                                                                                  
 block3b_se_reduce (Conv2D)     (None, 1, 1, 10)     2410        ['block3b_se_reshape[0][0]']     
                                                                                                  
 block3b_se_expand (Conv2D)     (None, 1, 1, 240)    2640        ['block3b_se_reduce[0][0]']      
                                                                                                  
 block3b_se_excite (Multiply)   (None, 28, 28, 240)  0           ['block3b_activation[0][0]',     
                                                                  'block3b_se_expand[0][0]']      
                                                                                                  
 block3b_project_conv (Conv2D)  (None, 28, 28, 40)   9600        ['block3b_se_excite[0][0]']      
                                                                                                  
 block3b_project_bn (BatchNorma  (None, 28, 28, 40)  160         ['block3b_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block3b_drop (Dropout)         (None, 28, 28, 40)   0           ['block3b_project_bn[0][0]']     
                                                                                                  
 block3b_add (Add)              (None, 28, 28, 40)   0           ['block3b_drop[0][0]',           
                                                                  'block3a_project_bn[0][0]']     
                                                                                                  
 block4a_expand_conv (Conv2D)   (None, 28, 28, 240)  9600        ['block3b_add[0][0]']            
                                                                                                  
 block4a_expand_bn (BatchNormal  (None, 28, 28, 240)  960        ['block4a_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block4a_expand_activation (Act  (None, 28, 28, 240)  0          ['block4a_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block4a_dwconv_pad (ZeroPaddin  (None, 29, 29, 240)  0          ['block4a_expand_activation[0][0]
 g2D)                                                            ']                               
                                                                                                  
 block4a_dwconv (DepthwiseConv2  (None, 14, 14, 240)  2160       ['block4a_dwconv_pad[0][0]']     
 D)                                                                                               
                                                                                                  
 block4a_bn (BatchNormalization  (None, 14, 14, 240)  960        ['block4a_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block4a_activation (Activation  (None, 14, 14, 240)  0          ['block4a_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block4a_se_squeeze (GlobalAver  (None, 240)         0           ['block4a_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block4a_se_reshape (Reshape)   (None, 1, 1, 240)    0           ['block4a_se_squeeze[0][0]']     
                                                                                                  
 block4a_se_reduce (Conv2D)     (None, 1, 1, 10)     2410        ['block4a_se_reshape[0][0]']     
                                                                                                  
 block4a_se_expand (Conv2D)     (None, 1, 1, 240)    2640        ['block4a_se_reduce[0][0]']      
                                                                                                  
 block4a_se_excite (Multiply)   (None, 14, 14, 240)  0           ['block4a_activation[0][0]',     
                                                                  'block4a_se_expand[0][0]']      
                                                                                                  
 block4a_project_conv (Conv2D)  (None, 14, 14, 80)   19200       ['block4a_se_excite[0][0]']      
                                                                                                  
 block4a_project_bn (BatchNorma  (None, 14, 14, 80)  320         ['block4a_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block4b_expand_conv (Conv2D)   (None, 14, 14, 480)  38400       ['block4a_project_bn[0][0]']     
                                                                                                  
 block4b_expand_bn (BatchNormal  (None, 14, 14, 480)  1920       ['block4b_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block4b_expand_activation (Act  (None, 14, 14, 480)  0          ['block4b_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block4b_dwconv (DepthwiseConv2  (None, 14, 14, 480)  4320       ['block4b_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block4b_bn (BatchNormalization  (None, 14, 14, 480)  1920       ['block4b_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block4b_activation (Activation  (None, 14, 14, 480)  0          ['block4b_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block4b_se_squeeze (GlobalAver  (None, 480)         0           ['block4b_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block4b_se_reshape (Reshape)   (None, 1, 1, 480)    0           ['block4b_se_squeeze[0][0]']     
                                                                                                  
 block4b_se_reduce (Conv2D)     (None, 1, 1, 20)     9620        ['block4b_se_reshape[0][0]']     
                                                                                                  
 block4b_se_expand (Conv2D)     (None, 1, 1, 480)    10080       ['block4b_se_reduce[0][0]']      
                                                                                                  
 block4b_se_excite (Multiply)   (None, 14, 14, 480)  0           ['block4b_activation[0][0]',     
                                                                  'block4b_se_expand[0][0]']      
                                                                                                  
 block4b_project_conv (Conv2D)  (None, 14, 14, 80)   38400       ['block4b_se_excite[0][0]']      
                                                                                                  
 block4b_project_bn (BatchNorma  (None, 14, 14, 80)  320         ['block4b_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block4b_drop (Dropout)         (None, 14, 14, 80)   0           ['block4b_project_bn[0][0]']     
                                                                                                  
 block4b_add (Add)              (None, 14, 14, 80)   0           ['block4b_drop[0][0]',           
                                                                  'block4a_project_bn[0][0]']     
                                                                                                  
 block4c_expand_conv (Conv2D)   (None, 14, 14, 480)  38400       ['block4b_add[0][0]']            
                                                                                                  
 block4c_expand_bn (BatchNormal  (None, 14, 14, 480)  1920       ['block4c_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block4c_expand_activation (Act  (None, 14, 14, 480)  0          ['block4c_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block4c_dwconv (DepthwiseConv2  (None, 14, 14, 480)  4320       ['block4c_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block4c_bn (BatchNormalization  (None, 14, 14, 480)  1920       ['block4c_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block4c_activation (Activation  (None, 14, 14, 480)  0          ['block4c_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block4c_se_squeeze (GlobalAver  (None, 480)         0           ['block4c_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block4c_se_reshape (Reshape)   (None, 1, 1, 480)    0           ['block4c_se_squeeze[0][0]']     
                                                                                                  
 block4c_se_reduce (Conv2D)     (None, 1, 1, 20)     9620        ['block4c_se_reshape[0][0]']     
                                                                                                  
 block4c_se_expand (Conv2D)     (None, 1, 1, 480)    10080       ['block4c_se_reduce[0][0]']      
                                                                                                  
 block4c_se_excite (Multiply)   (None, 14, 14, 480)  0           ['block4c_activation[0][0]',     
                                                                  'block4c_se_expand[0][0]']      
                                                                                                  
 block4c_project_conv (Conv2D)  (None, 14, 14, 80)   38400       ['block4c_se_excite[0][0]']      
                                                                                                  
 block4c_project_bn (BatchNorma  (None, 14, 14, 80)  320         ['block4c_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block4c_drop (Dropout)         (None, 14, 14, 80)   0           ['block4c_project_bn[0][0]']     
                                                                                                  
 block4c_add (Add)              (None, 14, 14, 80)   0           ['block4c_drop[0][0]',           
                                                                  'block4b_add[0][0]']            
                                                                                                  
 block5a_expand_conv (Conv2D)   (None, 14, 14, 480)  38400       ['block4c_add[0][0]']            
                                                                                                  
 block5a_expand_bn (BatchNormal  (None, 14, 14, 480)  1920       ['block5a_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block5a_expand_activation (Act  (None, 14, 14, 480)  0          ['block5a_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block5a_dwconv (DepthwiseConv2  (None, 14, 14, 480)  12000      ['block5a_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block5a_bn (BatchNormalization  (None, 14, 14, 480)  1920       ['block5a_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block5a_activation (Activation  (None, 14, 14, 480)  0          ['block5a_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block5a_se_squeeze (GlobalAver  (None, 480)         0           ['block5a_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block5a_se_reshape (Reshape)   (None, 1, 1, 480)    0           ['block5a_se_squeeze[0][0]']     
                                                                                                  
 block5a_se_reduce (Conv2D)     (None, 1, 1, 20)     9620        ['block5a_se_reshape[0][0]']     
                                                                                                  
 block5a_se_expand (Conv2D)     (None, 1, 1, 480)    10080       ['block5a_se_reduce[0][0]']      
                                                                                                  
 block5a_se_excite (Multiply)   (None, 14, 14, 480)  0           ['block5a_activation[0][0]',     
                                                                  'block5a_se_expand[0][0]']      
                                                                                                  
 block5a_project_conv (Conv2D)  (None, 14, 14, 112)  53760       ['block5a_se_excite[0][0]']      
                                                                                                  
 block5a_project_bn (BatchNorma  (None, 14, 14, 112)  448        ['block5a_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block5b_expand_conv (Conv2D)   (None, 14, 14, 672)  75264       ['block5a_project_bn[0][0]']     
                                                                                                  
 block5b_expand_bn (BatchNormal  (None, 14, 14, 672)  2688       ['block5b_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block5b_expand_activation (Act  (None, 14, 14, 672)  0          ['block5b_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block5b_dwconv (DepthwiseConv2  (None, 14, 14, 672)  16800      ['block5b_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block5b_bn (BatchNormalization  (None, 14, 14, 672)  2688       ['block5b_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block5b_activation (Activation  (None, 14, 14, 672)  0          ['block5b_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block5b_se_squeeze (GlobalAver  (None, 672)         0           ['block5b_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block5b_se_reshape (Reshape)   (None, 1, 1, 672)    0           ['block5b_se_squeeze[0][0]']     
                                                                                                  
 block5b_se_reduce (Conv2D)     (None, 1, 1, 28)     18844       ['block5b_se_reshape[0][0]']     
                                                                                                  
 block5b_se_expand (Conv2D)     (None, 1, 1, 672)    19488       ['block5b_se_reduce[0][0]']      
                                                                                                  
 block5b_se_excite (Multiply)   (None, 14, 14, 672)  0           ['block5b_activation[0][0]',     
                                                                  'block5b_se_expand[0][0]']      
                                                                                                  
 block5b_project_conv (Conv2D)  (None, 14, 14, 112)  75264       ['block5b_se_excite[0][0]']      
                                                                                                  
 block5b_project_bn (BatchNorma  (None, 14, 14, 112)  448        ['block5b_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block5b_drop (Dropout)         (None, 14, 14, 112)  0           ['block5b_project_bn[0][0]']     
                                                                                                  
 block5b_add (Add)              (None, 14, 14, 112)  0           ['block5b_drop[0][0]',           
                                                                  'block5a_project_bn[0][0]']     
                                                                                                  
 block5c_expand_conv (Conv2D)   (None, 14, 14, 672)  75264       ['block5b_add[0][0]']            
                                                                                                  
 block5c_expand_bn (BatchNormal  (None, 14, 14, 672)  2688       ['block5c_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block5c_expand_activation (Act  (None, 14, 14, 672)  0          ['block5c_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block5c_dwconv (DepthwiseConv2  (None, 14, 14, 672)  16800      ['block5c_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block5c_bn (BatchNormalization  (None, 14, 14, 672)  2688       ['block5c_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block5c_activation (Activation  (None, 14, 14, 672)  0          ['block5c_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block5c_se_squeeze (GlobalAver  (None, 672)         0           ['block5c_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block5c_se_reshape (Reshape)   (None, 1, 1, 672)    0           ['block5c_se_squeeze[0][0]']     
                                                                                                  
 block5c_se_reduce (Conv2D)     (None, 1, 1, 28)     18844       ['block5c_se_reshape[0][0]']     
                                                                                                  
 block5c_se_expand (Conv2D)     (None, 1, 1, 672)    19488       ['block5c_se_reduce[0][0]']      
                                                                                                  
 block5c_se_excite (Multiply)   (None, 14, 14, 672)  0           ['block5c_activation[0][0]',     
                                                                  'block5c_se_expand[0][0]']      
                                                                                                  
 block5c_project_conv (Conv2D)  (None, 14, 14, 112)  75264       ['block5c_se_excite[0][0]']      
                                                                                                  
 block5c_project_bn (BatchNorma  (None, 14, 14, 112)  448        ['block5c_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block5c_drop (Dropout)         (None, 14, 14, 112)  0           ['block5c_project_bn[0][0]']     
                                                                                                  
 block5c_add (Add)              (None, 14, 14, 112)  0           ['block5c_drop[0][0]',           
                                                                  'block5b_add[0][0]']            
                                                                                                  
 block6a_expand_conv (Conv2D)   (None, 14, 14, 672)  75264       ['block5c_add[0][0]']            
                                                                                                  
 block6a_expand_bn (BatchNormal  (None, 14, 14, 672)  2688       ['block6a_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block6a_expand_activation (Act  (None, 14, 14, 672)  0          ['block6a_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block6a_dwconv_pad (ZeroPaddin  (None, 17, 17, 672)  0          ['block6a_expand_activation[0][0]
 g2D)                                                            ']                               
                                                                                                  
 block6a_dwconv (DepthwiseConv2  (None, 7, 7, 672)   16800       ['block6a_dwconv_pad[0][0]']     
 D)                                                                                               
                                                                                                  
 block6a_bn (BatchNormalization  (None, 7, 7, 672)   2688        ['block6a_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block6a_activation (Activation  (None, 7, 7, 672)   0           ['block6a_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block6a_se_squeeze (GlobalAver  (None, 672)         0           ['block6a_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block6a_se_reshape (Reshape)   (None, 1, 1, 672)    0           ['block6a_se_squeeze[0][0]']     
                                                                                                  
 block6a_se_reduce (Conv2D)     (None, 1, 1, 28)     18844       ['block6a_se_reshape[0][0]']     
                                                                                                  
 block6a_se_expand (Conv2D)     (None, 1, 1, 672)    19488       ['block6a_se_reduce[0][0]']      
                                                                                                  
 block6a_se_excite (Multiply)   (None, 7, 7, 672)    0           ['block6a_activation[0][0]',     
                                                                  'block6a_se_expand[0][0]']      
                                                                                                  
 block6a_project_conv (Conv2D)  (None, 7, 7, 192)    129024      ['block6a_se_excite[0][0]']      
                                                                                                  
 block6a_project_bn (BatchNorma  (None, 7, 7, 192)   768         ['block6a_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block6b_expand_conv (Conv2D)   (None, 7, 7, 1152)   221184      ['block6a_project_bn[0][0]']     
                                                                                                  
 block6b_expand_bn (BatchNormal  (None, 7, 7, 1152)  4608        ['block6b_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block6b_expand_activation (Act  (None, 7, 7, 1152)  0           ['block6b_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block6b_dwconv (DepthwiseConv2  (None, 7, 7, 1152)  28800       ['block6b_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block6b_bn (BatchNormalization  (None, 7, 7, 1152)  4608        ['block6b_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block6b_activation (Activation  (None, 7, 7, 1152)  0           ['block6b_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block6b_se_squeeze (GlobalAver  (None, 1152)        0           ['block6b_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block6b_se_reshape (Reshape)   (None, 1, 1, 1152)   0           ['block6b_se_squeeze[0][0]']     
                                                                                                  
 block6b_se_reduce (Conv2D)     (None, 1, 1, 48)     55344       ['block6b_se_reshape[0][0]']     
                                                                                                  
 block6b_se_expand (Conv2D)     (None, 1, 1, 1152)   56448       ['block6b_se_reduce[0][0]']      
                                                                                                  
 block6b_se_excite (Multiply)   (None, 7, 7, 1152)   0           ['block6b_activation[0][0]',     
                                                                  'block6b_se_expand[0][0]']      
                                                                                                  
 block6b_project_conv (Conv2D)  (None, 7, 7, 192)    221184      ['block6b_se_excite[0][0]']      
                                                                                                  
 block6b_project_bn (BatchNorma  (None, 7, 7, 192)   768         ['block6b_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block6b_drop (Dropout)         (None, 7, 7, 192)    0           ['block6b_project_bn[0][0]']     
                                                                                                  
 block6b_add (Add)              (None, 7, 7, 192)    0           ['block6b_drop[0][0]',           
                                                                  'block6a_project_bn[0][0]']     
                                                                                                  
 block6c_expand_conv (Conv2D)   (None, 7, 7, 1152)   221184      ['block6b_add[0][0]']            
                                                                                                  
 block6c_expand_bn (BatchNormal  (None, 7, 7, 1152)  4608        ['block6c_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block6c_expand_activation (Act  (None, 7, 7, 1152)  0           ['block6c_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block6c_dwconv (DepthwiseConv2  (None, 7, 7, 1152)  28800       ['block6c_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block6c_bn (BatchNormalization  (None, 7, 7, 1152)  4608        ['block6c_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block6c_activation (Activation  (None, 7, 7, 1152)  0           ['block6c_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block6c_se_squeeze (GlobalAver  (None, 1152)        0           ['block6c_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block6c_se_reshape (Reshape)   (None, 1, 1, 1152)   0           ['block6c_se_squeeze[0][0]']     
                                                                                                  
 block6c_se_reduce (Conv2D)     (None, 1, 1, 48)     55344       ['block6c_se_reshape[0][0]']     
                                                                                                  
 block6c_se_expand (Conv2D)     (None, 1, 1, 1152)   56448       ['block6c_se_reduce[0][0]']      
                                                                                                  
 block6c_se_excite (Multiply)   (None, 7, 7, 1152)   0           ['block6c_activation[0][0]',     
                                                                  'block6c_se_expand[0][0]']      
                                                                                                  
 block6c_project_conv (Conv2D)  (None, 7, 7, 192)    221184      ['block6c_se_excite[0][0]']      
                                                                                                  
 block6c_project_bn (BatchNorma  (None, 7, 7, 192)   768         ['block6c_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block6c_drop (Dropout)         (None, 7, 7, 192)    0           ['block6c_project_bn[0][0]']     
                                                                                                  
 block6c_add (Add)              (None, 7, 7, 192)    0           ['block6c_drop[0][0]',           
                                                                  'block6b_add[0][0]']            
                                                                                                  
 block6d_expand_conv (Conv2D)   (None, 7, 7, 1152)   221184      ['block6c_add[0][0]']            
                                                                                                  
 block6d_expand_bn (BatchNormal  (None, 7, 7, 1152)  4608        ['block6d_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block6d_expand_activation (Act  (None, 7, 7, 1152)  0           ['block6d_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block6d_dwconv (DepthwiseConv2  (None, 7, 7, 1152)  28800       ['block6d_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block6d_bn (BatchNormalization  (None, 7, 7, 1152)  4608        ['block6d_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block6d_activation (Activation  (None, 7, 7, 1152)  0           ['block6d_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block6d_se_squeeze (GlobalAver  (None, 1152)        0           ['block6d_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block6d_se_reshape (Reshape)   (None, 1, 1, 1152)   0           ['block6d_se_squeeze[0][0]']     
                                                                                                  
 block6d_se_reduce (Conv2D)     (None, 1, 1, 48)     55344       ['block6d_se_reshape[0][0]']     
                                                                                                  
 block6d_se_expand (Conv2D)     (None, 1, 1, 1152)   56448       ['block6d_se_reduce[0][0]']      
                                                                                                  
 block6d_se_excite (Multiply)   (None, 7, 7, 1152)   0           ['block6d_activation[0][0]',     
                                                                  'block6d_se_expand[0][0]']      
                                                                                                  
 block6d_project_conv (Conv2D)  (None, 7, 7, 192)    221184      ['block6d_se_excite[0][0]']      
                                                                                                  
 block6d_project_bn (BatchNorma  (None, 7, 7, 192)   768         ['block6d_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block6d_drop (Dropout)         (None, 7, 7, 192)    0           ['block6d_project_bn[0][0]']     
                                                                                                  
 block6d_add (Add)              (None, 7, 7, 192)    0           ['block6d_drop[0][0]',           
                                                                  'block6c_add[0][0]']            
                                                                                                  
 block7a_expand_conv (Conv2D)   (None, 7, 7, 1152)   221184      ['block6d_add[0][0]']            
                                                                                                  
 block7a_expand_bn (BatchNormal  (None, 7, 7, 1152)  4608        ['block7a_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block7a_expand_activation (Act  (None, 7, 7, 1152)  0           ['block7a_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block7a_dwconv (DepthwiseConv2  (None, 7, 7, 1152)  10368       ['block7a_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block7a_bn (BatchNormalization  (None, 7, 7, 1152)  4608        ['block7a_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block7a_activation (Activation  (None, 7, 7, 1152)  0           ['block7a_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block7a_se_squeeze (GlobalAver  (None, 1152)        0           ['block7a_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block7a_se_reshape (Reshape)   (None, 1, 1, 1152)   0           ['block7a_se_squeeze[0][0]']     
                                                                                                  
 block7a_se_reduce (Conv2D)     (None, 1, 1, 48)     55344       ['block7a_se_reshape[0][0]']     
                                                                                                  
 block7a_se_expand (Conv2D)     (None, 1, 1, 1152)   56448       ['block7a_se_reduce[0][0]']      
                                                                                                  
 block7a_se_excite (Multiply)   (None, 7, 7, 1152)   0           ['block7a_activation[0][0]',     
                                                                  'block7a_se_expand[0][0]']      
                                                                                                  
 block7a_project_conv (Conv2D)  (None, 7, 7, 320)    368640      ['block7a_se_excite[0][0]']      
                                                                                                  
 block7a_project_bn (BatchNorma  (None, 7, 7, 320)   1280        ['block7a_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 top_conv (Conv2D)              (None, 7, 7, 1280)   409600      ['block7a_project_bn[0][0]']     
                                                                                                  
 top_bn (BatchNormalization)    (None, 7, 7, 1280)   5120        ['top_conv[0][0]']               
                                                                                                  
 top_activation (Activation)    (None, 7, 7, 1280)   0           ['top_bn[0][0]']                 
                                                                                                  
 flatten_7 (Flatten)            (None, 62720)        0           ['top_activation[0][0]']         
                                                                                                  
 batch_normalization_201 (Batch  (None, 62720)       250880      ['flatten_7[0][0]']              
 Normalization)                                                                                   
                                                                                                  
 dense_28 (Dense)               (None, 256)          16056576    ['batch_normalization_201[0][0]']
                                                                                                  
 dropout_11 (Dropout)           (None, 256)          0           ['dense_28[0][0]']               
                                                                                                  
 dense_29 (Dense)               (None, 2)            514         ['dropout_11[0][0]']             
                                                                                                  
==================================================================================================
Total params: 20,357,541
Trainable params: 17,075,762
Non-trainable params: 3,281,779
__________________________________________________________________________________________________
Epoch 1/50
10/10 [==============================] - 23s 2s/step - loss: 6.1554 - accuracy: 0.5512 - val_loss: 6.7539 - val_accuracy: 0.3465 - lr: 1.0000e-05
Epoch 2/50
10/10 [==============================] - 12s 1s/step - loss: 5.9171 - accuracy: 0.6568 - val_loss: 6.5205 - val_accuracy: 0.3663 - lr: 1.0000e-05
Epoch 3/50
10/10 [==============================] - 12s 1s/step - loss: 5.8170 - accuracy: 0.6766 - val_loss: 6.1044 - val_accuracy: 0.4356 - lr: 1.0000e-05
Epoch 4/50
10/10 [==============================] - 11s 1s/step - loss: 5.6797 - accuracy: 0.7624 - val_loss: 5.8004 - val_accuracy: 0.6040 - lr: 1.0000e-05
Epoch 5/50
10/10 [==============================] - 13s 1s/step - loss: 5.4958 - accuracy: 0.8020 - val_loss: 5.6887 - val_accuracy: 0.6832 - lr: 1.0000e-05
Epoch 6/50
10/10 [==============================] - 12s 1s/step - loss: 5.3879 - accuracy: 0.8317 - val_loss: 5.7121 - val_accuracy: 0.6436 - lr: 1.0000e-05
Epoch 7/50
10/10 [==============================] - 11s 1s/step - loss: 5.3088 - accuracy: 0.8911 - val_loss: 5.7563 - val_accuracy: 0.6238 - lr: 1.0000e-05
Epoch 8/50
10/10 [==============================] - 12s 1s/step - loss: 5.3761 - accuracy: 0.8515 - val_loss: 5.6182 - val_accuracy: 0.7129 - lr: 1.0000e-05
Epoch 9/50
10/10 [==============================] - 13s 1s/step - loss: 5.2939 - accuracy: 0.9043 - val_loss: 5.5683 - val_accuracy: 0.7426 - lr: 1.0000e-05
Epoch 10/50
10/10 [==============================] - 12s 1s/step - loss: 5.2790 - accuracy: 0.8911 - val_loss: 5.5710 - val_accuracy: 0.7525 - lr: 1.0000e-05
Epoch 11/50
10/10 [==============================] - 12s 1s/step - loss: 5.2324 - accuracy: 0.9307 - val_loss: 5.5866 - val_accuracy: 0.7525 - lr: 1.0000e-05
Epoch 12/50
10/10 [==============================] - 12s 1s/step - loss: 5.2554 - accuracy: 0.8977 - val_loss: 5.5523 - val_accuracy: 0.7624 - lr: 1.0000e-05
Epoch 13/50
10/10 [==============================] - 12s 1s/step - loss: 5.1538 - accuracy: 0.9406 - val_loss: 5.4927 - val_accuracy: 0.7822 - lr: 1.0000e-05
Epoch 14/50
10/10 [==============================] - 13s 1s/step - loss: 5.1943 - accuracy: 0.9241 - val_loss: 5.3930 - val_accuracy: 0.8218 - lr: 1.0000e-05
Epoch 15/50
10/10 [==============================] - 14s 1s/step - loss: 5.1337 - accuracy: 0.9439 - val_loss: 5.3407 - val_accuracy: 0.8416 - lr: 1.0000e-05
Epoch 16/50
10/10 [==============================] - 12s 1s/step - loss: 5.1751 - accuracy: 0.9340 - val_loss: 5.3219 - val_accuracy: 0.8515 - lr: 1.0000e-05
Epoch 17/50
10/10 [==============================] - 13s 1s/step - loss: 5.1068 - accuracy: 0.9406 - val_loss: 5.3171 - val_accuracy: 0.8515 - lr: 1.0000e-05
Epoch 18/50
10/10 [==============================] - 12s 1s/step - loss: 5.1548 - accuracy: 0.9307 - val_loss: 5.3204 - val_accuracy: 0.8416 - lr: 1.0000e-05
Epoch 19/50
10/10 [==============================] - 13s 1s/step - loss: 5.0642 - accuracy: 0.9538 - val_loss: 5.3254 - val_accuracy: 0.8416 - lr: 1.0000e-05
Epoch 20/50
10/10 [==============================] - 13s 1s/step - loss: 5.0809 - accuracy: 0.9406 - val_loss: 5.2834 - val_accuracy: 0.8614 - lr: 1.0000e-05
Epoch 21/50
10/10 [==============================] - 12s 1s/step - loss: 5.0297 - accuracy: 0.9670 - val_loss: 5.2462 - val_accuracy: 0.8812 - lr: 1.0000e-05
Epoch 22/50
10/10 [==============================] - 12s 1s/step - loss: 5.0684 - accuracy: 0.9472 - val_loss: 5.2356 - val_accuracy: 0.8812 - lr: 1.0000e-05
Epoch 23/50
10/10 [==============================] - 13s 1s/step - loss: 5.0679 - accuracy: 0.9274 - val_loss: 5.2086 - val_accuracy: 0.8911 - lr: 1.0000e-05
Epoch 24/50
10/10 [==============================] - 14s 1s/step - loss: 5.0158 - accuracy: 0.9637 - val_loss: 5.1890 - val_accuracy: 0.8911 - lr: 1.0000e-05
Epoch 25/50
10/10 [==============================] - 13s 1s/step - loss: 5.0237 - accuracy: 0.9538 - val_loss: 5.1790 - val_accuracy: 0.9010 - lr: 1.0000e-05
Epoch 26/50
10/10 [==============================] - 12s 1s/step - loss: 4.9856 - accuracy: 0.9604 - val_loss: 5.1695 - val_accuracy: 0.9010 - lr: 1.0000e-05
Epoch 27/50
10/10 [==============================] - 12s 1s/step - loss: 5.0161 - accuracy: 0.9538 - val_loss: 5.1612 - val_accuracy: 0.9109 - lr: 1.0000e-05
Epoch 28/50
10/10 [==============================] - 14s 1s/step - loss: 4.9539 - accuracy: 0.9670 - val_loss: 5.1487 - val_accuracy: 0.8911 - lr: 1.0000e-05
Epoch 29/50
10/10 [==============================] - 12s 1s/step - loss: 4.9774 - accuracy: 0.9703 - val_loss: 5.1357 - val_accuracy: 0.9010 - lr: 1.0000e-05
Epoch 30/50
10/10 [==============================] - 12s 1s/step - loss: 4.9547 - accuracy: 0.9637 - val_loss: 5.1234 - val_accuracy: 0.9208 - lr: 1.0000e-05
Epoch 31/50
10/10 [==============================] - 13s 1s/step - loss: 4.9078 - accuracy: 0.9802 - val_loss: 5.1211 - val_accuracy: 0.9109 - lr: 1.0000e-05
Epoch 32/50
10/10 [==============================] - 13s 1s/step - loss: 4.9773 - accuracy: 0.9439 - val_loss: 5.1154 - val_accuracy: 0.9109 - lr: 1.0000e-05
Epoch 33/50
10/10 [==============================] - 12s 1s/step - loss: 4.8981 - accuracy: 0.9736 - val_loss: 5.1178 - val_accuracy: 0.9010 - lr: 1.0000e-05
Epoch 34/50
10/10 [==============================] - 13s 1s/step - loss: 4.8845 - accuracy: 0.9736 - val_loss: 5.1013 - val_accuracy: 0.9208 - lr: 1.0000e-05
Epoch 35/50
10/10 [==============================] - 12s 1s/step - loss: 4.8698 - accuracy: 0.9769 - val_loss: 5.0912 - val_accuracy: 0.9109 - lr: 1.0000e-05
Epoch 36/50
10/10 [==============================] - 12s 1s/step - loss: 4.9046 - accuracy: 0.9538 - val_loss: 5.0868 - val_accuracy: 0.9109 - lr: 1.0000e-05
Epoch 37/50
10/10 [==============================] - 12s 1s/step - loss: 4.8788 - accuracy: 0.9604 - val_loss: 5.1023 - val_accuracy: 0.9109 - lr: 1.0000e-05
Epoch 38/50
10/10 [==============================] - 12s 1s/step - loss: 4.8542 - accuracy: 0.9802 - val_loss: 5.1051 - val_accuracy: 0.9010 - lr: 1.0000e-05
Epoch 39/50
10/10 [==============================] - 12s 1s/step - loss: 4.8843 - accuracy: 0.9604 - val_loss: 5.1199 - val_accuracy: 0.8911 - lr: 1.0000e-05
Epoch 40/50
10/10 [==============================] - 12s 1s/step - loss: 4.8492 - accuracy: 0.9802 - val_loss: 5.1112 - val_accuracy: 0.8812 - lr: 1.0000e-05
Epoch 41/50
10/10 [==============================] - 13s 1s/step - loss: 4.8227 - accuracy: 0.9703 - val_loss: 5.0826 - val_accuracy: 0.9010 - lr: 1.0000e-05
Epoch 42/50
10/10 [==============================] - 13s 1s/step - loss: 4.8058 - accuracy: 0.9769 - val_loss: 5.0740 - val_accuracy: 0.8911 - lr: 1.0000e-05
Epoch 43/50
10/10 [==============================] - 12s 1s/step - loss: 4.7871 - accuracy: 0.9802 - val_loss: 5.0691 - val_accuracy: 0.9010 - lr: 1.0000e-05
Epoch 44/50
10/10 [==============================] - 11s 1s/step - loss: 4.7888 - accuracy: 0.9769 - val_loss: 5.0540 - val_accuracy: 0.9010 - lr: 1.0000e-05
Epoch 45/50
10/10 [==============================] - 12s 1s/step - loss: 4.7815 - accuracy: 0.9769 - val_loss: 5.0509 - val_accuracy: 0.9010 - lr: 1.0000e-05
Epoch 46/50
10/10 [==============================] - 16s 2s/step - loss: 4.7884 - accuracy: 0.9703 - val_loss: 5.0402 - val_accuracy: 0.9109 - lr: 1.0000e-05
Epoch 47/50
10/10 [==============================] - 14s 1s/step - loss: 4.7555 - accuracy: 0.9835 - val_loss: 5.0393 - val_accuracy: 0.9109 - lr: 1.0000e-05
Epoch 48/50
10/10 [==============================] - 12s 1s/step - loss: 4.7248 - accuracy: 0.9901 - val_loss: 5.0175 - val_accuracy: 0.9010 - lr: 1.0000e-05
Epoch 49/50
10/10 [==============================] - 12s 1s/step - loss: 4.7668 - accuracy: 0.9670 - val_loss: 4.9976 - val_accuracy: 0.9010 - lr: 1.0000e-05
Epoch 50/50
10/10 [==============================] - 12s 1s/step - loss: 4.7634 - accuracy: 0.9670 - val_loss: 4.9906 - val_accuracy: 0.8911 - lr: 1.0000e-05
4/4 [==============================] - 7s 426ms/step
              precision    recall  f1-score   support

           0       0.85      0.77      0.81        30
           1       0.91      0.94      0.92        71

    accuracy                           0.89       101
   macro avg       0.88      0.86      0.87       101
weighted avg       0.89      0.89      0.89       101



epoch=100
epoch=200结果相同
Model: "model_8"
__________________________________________________________________________________________________
 Layer (type)                   Output Shape         Param #     Connected to                     
==================================================================================================
 input_12 (InputLayer)          [(None, 224, 224, 3  0           []                               
                                )]                                                                
                                                                                                  
 rescaling_6 (Rescaling)        (None, 224, 224, 3)  0           ['input_12[0][0]']               
                                                                                                  
 normalization_3 (Normalization  (None, 224, 224, 3)  7          ['rescaling_6[0][0]']            
 )                                                                                                
                                                                                                  
 rescaling_7 (Rescaling)        (None, 224, 224, 3)  0           ['normalization_3[0][0]']        
                                                                                                  
 stem_conv_pad (ZeroPadding2D)  (None, 225, 225, 3)  0           ['rescaling_7[0][0]']            
                                                                                                  
 stem_conv (Conv2D)             (None, 112, 112, 32  864         ['stem_conv_pad[0][0]']          
                                )                                                                 
                                                                                                  
 stem_bn (BatchNormalization)   (None, 112, 112, 32  128         ['stem_conv[0][0]']              
                                )                                                                 
                                                                                                  
 stem_activation (Activation)   (None, 112, 112, 32  0           ['stem_bn[0][0]']                
                                )                                                                 
                                                                                                  
 block1a_dwconv (DepthwiseConv2  (None, 112, 112, 32  288        ['stem_activation[0][0]']        
 D)                             )                                                                 
                                                                                                  
 block1a_bn (BatchNormalization  (None, 112, 112, 32  128        ['block1a_dwconv[0][0]']         
 )                              )                                                                 
                                                                                                  
 block1a_activation (Activation  (None, 112, 112, 32  0          ['block1a_bn[0][0]']             
 )                              )                                                                 
                                                                                                  
 block1a_se_squeeze (GlobalAver  (None, 32)          0           ['block1a_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block1a_se_reshape (Reshape)   (None, 1, 1, 32)     0           ['block1a_se_squeeze[0][0]']     
                                                                                                  
 block1a_se_reduce (Conv2D)     (None, 1, 1, 8)      264         ['block1a_se_reshape[0][0]']     
                                                                                                  
 block1a_se_expand (Conv2D)     (None, 1, 1, 32)     288         ['block1a_se_reduce[0][0]']      
                                                                                                  
 block1a_se_excite (Multiply)   (None, 112, 112, 32  0           ['block1a_activation[0][0]',     
                                )                                 'block1a_se_expand[0][0]']      
                                                                                                  
 block1a_project_conv (Conv2D)  (None, 112, 112, 16  512         ['block1a_se_excite[0][0]']      
                                )                                                                 
                                                                                                  
 block1a_project_bn (BatchNorma  (None, 112, 112, 16  64         ['block1a_project_conv[0][0]']   
 lization)                      )                                                                 
                                                                                                  
 block2a_expand_conv (Conv2D)   (None, 112, 112, 96  1536        ['block1a_project_bn[0][0]']     
                                )                                                                 
                                                                                                  
 block2a_expand_bn (BatchNormal  (None, 112, 112, 96  384        ['block2a_expand_conv[0][0]']    
 ization)                       )                                                                 
                                                                                                  
 block2a_expand_activation (Act  (None, 112, 112, 96  0          ['block2a_expand_bn[0][0]']      
 ivation)                       )                                                                 
                                                                                                  
 block2a_dwconv_pad (ZeroPaddin  (None, 113, 113, 96  0          ['block2a_expand_activation[0][0]
 g2D)                           )                                ']                               
                                                                                                  
 block2a_dwconv (DepthwiseConv2  (None, 56, 56, 96)  864         ['block2a_dwconv_pad[0][0]']     
 D)                                                                                               
                                                                                                  
 block2a_bn (BatchNormalization  (None, 56, 56, 96)  384         ['block2a_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block2a_activation (Activation  (None, 56, 56, 96)  0           ['block2a_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block2a_se_squeeze (GlobalAver  (None, 96)          0           ['block2a_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block2a_se_reshape (Reshape)   (None, 1, 1, 96)     0           ['block2a_se_squeeze[0][0]']     
                                                                                                  
 block2a_se_reduce (Conv2D)     (None, 1, 1, 4)      388         ['block2a_se_reshape[0][0]']     
                                                                                                  
 block2a_se_expand (Conv2D)     (None, 1, 1, 96)     480         ['block2a_se_reduce[0][0]']      
                                                                                                  
 block2a_se_excite (Multiply)   (None, 56, 56, 96)   0           ['block2a_activation[0][0]',     
                                                                  'block2a_se_expand[0][0]']      
                                                                                                  
 block2a_project_conv (Conv2D)  (None, 56, 56, 24)   2304        ['block2a_se_excite[0][0]']      
                                                                                                  
 block2a_project_bn (BatchNorma  (None, 56, 56, 24)  96          ['block2a_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block2b_expand_conv (Conv2D)   (None, 56, 56, 144)  3456        ['block2a_project_bn[0][0]']     
                                                                                                  
 block2b_expand_bn (BatchNormal  (None, 56, 56, 144)  576        ['block2b_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block2b_expand_activation (Act  (None, 56, 56, 144)  0          ['block2b_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block2b_dwconv (DepthwiseConv2  (None, 56, 56, 144)  1296       ['block2b_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block2b_bn (BatchNormalization  (None, 56, 56, 144)  576        ['block2b_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block2b_activation (Activation  (None, 56, 56, 144)  0          ['block2b_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block2b_se_squeeze (GlobalAver  (None, 144)         0           ['block2b_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block2b_se_reshape (Reshape)   (None, 1, 1, 144)    0           ['block2b_se_squeeze[0][0]']     
                                                                                                  
 block2b_se_reduce (Conv2D)     (None, 1, 1, 6)      870         ['block2b_se_reshape[0][0]']     
                                                                                                  
 block2b_se_expand (Conv2D)     (None, 1, 1, 144)    1008        ['block2b_se_reduce[0][0]']      
                                                                                                  
 block2b_se_excite (Multiply)   (None, 56, 56, 144)  0           ['block2b_activation[0][0]',     
                                                                  'block2b_se_expand[0][0]']      
                                                                                                  
 block2b_project_conv (Conv2D)  (None, 56, 56, 24)   3456        ['block2b_se_excite[0][0]']      
                                                                                                  
 block2b_project_bn (BatchNorma  (None, 56, 56, 24)  96          ['block2b_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block2b_drop (Dropout)         (None, 56, 56, 24)   0           ['block2b_project_bn[0][0]']     
                                                                                                  
 block2b_add (Add)              (None, 56, 56, 24)   0           ['block2b_drop[0][0]',           
                                                                  'block2a_project_bn[0][0]']     
                                                                                                  
 block3a_expand_conv (Conv2D)   (None, 56, 56, 144)  3456        ['block2b_add[0][0]']            
                                                                                                  
 block3a_expand_bn (BatchNormal  (None, 56, 56, 144)  576        ['block3a_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block3a_expand_activation (Act  (None, 56, 56, 144)  0          ['block3a_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block3a_dwconv_pad (ZeroPaddin  (None, 59, 59, 144)  0          ['block3a_expand_activation[0][0]
 g2D)                                                            ']                               
                                                                                                  
 block3a_dwconv (DepthwiseConv2  (None, 28, 28, 144)  3600       ['block3a_dwconv_pad[0][0]']     
 D)                                                                                               
                                                                                                  
 block3a_bn (BatchNormalization  (None, 28, 28, 144)  576        ['block3a_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block3a_activation (Activation  (None, 28, 28, 144)  0          ['block3a_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block3a_se_squeeze (GlobalAver  (None, 144)         0           ['block3a_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block3a_se_reshape (Reshape)   (None, 1, 1, 144)    0           ['block3a_se_squeeze[0][0]']     
                                                                                                  
 block3a_se_reduce (Conv2D)     (None, 1, 1, 6)      870         ['block3a_se_reshape[0][0]']     
                                                                                                  
 block3a_se_expand (Conv2D)     (None, 1, 1, 144)    1008        ['block3a_se_reduce[0][0]']      
                                                                                                  
 block3a_se_excite (Multiply)   (None, 28, 28, 144)  0           ['block3a_activation[0][0]',     
                                                                  'block3a_se_expand[0][0]']      
                                                                                                  
 block3a_project_conv (Conv2D)  (None, 28, 28, 40)   5760        ['block3a_se_excite[0][0]']      
                                                                                                  
 block3a_project_bn (BatchNorma  (None, 28, 28, 40)  160         ['block3a_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block3b_expand_conv (Conv2D)   (None, 28, 28, 240)  9600        ['block3a_project_bn[0][0]']     
                                                                                                  
 block3b_expand_bn (BatchNormal  (None, 28, 28, 240)  960        ['block3b_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block3b_expand_activation (Act  (None, 28, 28, 240)  0          ['block3b_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block3b_dwconv (DepthwiseConv2  (None, 28, 28, 240)  6000       ['block3b_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block3b_bn (BatchNormalization  (None, 28, 28, 240)  960        ['block3b_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block3b_activation (Activation  (None, 28, 28, 240)  0          ['block3b_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block3b_se_squeeze (GlobalAver  (None, 240)         0           ['block3b_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block3b_se_reshape (Reshape)   (None, 1, 1, 240)    0           ['block3b_se_squeeze[0][0]']     
                                                                                                  
 block3b_se_reduce (Conv2D)     (None, 1, 1, 10)     2410        ['block3b_se_reshape[0][0]']     
                                                                                                  
 block3b_se_expand (Conv2D)     (None, 1, 1, 240)    2640        ['block3b_se_reduce[0][0]']      
                                                                                                  
 block3b_se_excite (Multiply)   (None, 28, 28, 240)  0           ['block3b_activation[0][0]',     
                                                                  'block3b_se_expand[0][0]']      
                                                                                                  
 block3b_project_conv (Conv2D)  (None, 28, 28, 40)   9600        ['block3b_se_excite[0][0]']      
                                                                                                  
 block3b_project_bn (BatchNorma  (None, 28, 28, 40)  160         ['block3b_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block3b_drop (Dropout)         (None, 28, 28, 40)   0           ['block3b_project_bn[0][0]']     
                                                                                                  
 block3b_add (Add)              (None, 28, 28, 40)   0           ['block3b_drop[0][0]',           
                                                                  'block3a_project_bn[0][0]']     
                                                                                                  
 block4a_expand_conv (Conv2D)   (None, 28, 28, 240)  9600        ['block3b_add[0][0]']            
                                                                                                  
 block4a_expand_bn (BatchNormal  (None, 28, 28, 240)  960        ['block4a_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block4a_expand_activation (Act  (None, 28, 28, 240)  0          ['block4a_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block4a_dwconv_pad (ZeroPaddin  (None, 29, 29, 240)  0          ['block4a_expand_activation[0][0]
 g2D)                                                            ']                               
                                                                                                  
 block4a_dwconv (DepthwiseConv2  (None, 14, 14, 240)  2160       ['block4a_dwconv_pad[0][0]']     
 D)                                                                                               
                                                                                                  
 block4a_bn (BatchNormalization  (None, 14, 14, 240)  960        ['block4a_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block4a_activation (Activation  (None, 14, 14, 240)  0          ['block4a_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block4a_se_squeeze (GlobalAver  (None, 240)         0           ['block4a_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block4a_se_reshape (Reshape)   (None, 1, 1, 240)    0           ['block4a_se_squeeze[0][0]']     
                                                                                                  
 block4a_se_reduce (Conv2D)     (None, 1, 1, 10)     2410        ['block4a_se_reshape[0][0]']     
                                                                                                  
 block4a_se_expand (Conv2D)     (None, 1, 1, 240)    2640        ['block4a_se_reduce[0][0]']      
                                                                                                  
 block4a_se_excite (Multiply)   (None, 14, 14, 240)  0           ['block4a_activation[0][0]',     
                                                                  'block4a_se_expand[0][0]']      
                                                                                                  
 block4a_project_conv (Conv2D)  (None, 14, 14, 80)   19200       ['block4a_se_excite[0][0]']      
                                                                                                  
 block4a_project_bn (BatchNorma  (None, 14, 14, 80)  320         ['block4a_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block4b_expand_conv (Conv2D)   (None, 14, 14, 480)  38400       ['block4a_project_bn[0][0]']     
                                                                                                  
 block4b_expand_bn (BatchNormal  (None, 14, 14, 480)  1920       ['block4b_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block4b_expand_activation (Act  (None, 14, 14, 480)  0          ['block4b_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block4b_dwconv (DepthwiseConv2  (None, 14, 14, 480)  4320       ['block4b_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block4b_bn (BatchNormalization  (None, 14, 14, 480)  1920       ['block4b_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block4b_activation (Activation  (None, 14, 14, 480)  0          ['block4b_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block4b_se_squeeze (GlobalAver  (None, 480)         0           ['block4b_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block4b_se_reshape (Reshape)   (None, 1, 1, 480)    0           ['block4b_se_squeeze[0][0]']     
                                                                                                  
 block4b_se_reduce (Conv2D)     (None, 1, 1, 20)     9620        ['block4b_se_reshape[0][0]']     
                                                                                                  
 block4b_se_expand (Conv2D)     (None, 1, 1, 480)    10080       ['block4b_se_reduce[0][0]']      
                                                                                                  
 block4b_se_excite (Multiply)   (None, 14, 14, 480)  0           ['block4b_activation[0][0]',     
                                                                  'block4b_se_expand[0][0]']      
                                                                                                  
 block4b_project_conv (Conv2D)  (None, 14, 14, 80)   38400       ['block4b_se_excite[0][0]']      
                                                                                                  
 block4b_project_bn (BatchNorma  (None, 14, 14, 80)  320         ['block4b_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block4b_drop (Dropout)         (None, 14, 14, 80)   0           ['block4b_project_bn[0][0]']     
                                                                                                  
 block4b_add (Add)              (None, 14, 14, 80)   0           ['block4b_drop[0][0]',           
                                                                  'block4a_project_bn[0][0]']     
                                                                                                  
 block4c_expand_conv (Conv2D)   (None, 14, 14, 480)  38400       ['block4b_add[0][0]']            
                                                                                                  
 block4c_expand_bn (BatchNormal  (None, 14, 14, 480)  1920       ['block4c_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block4c_expand_activation (Act  (None, 14, 14, 480)  0          ['block4c_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block4c_dwconv (DepthwiseConv2  (None, 14, 14, 480)  4320       ['block4c_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block4c_bn (BatchNormalization  (None, 14, 14, 480)  1920       ['block4c_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block4c_activation (Activation  (None, 14, 14, 480)  0          ['block4c_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block4c_se_squeeze (GlobalAver  (None, 480)         0           ['block4c_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block4c_se_reshape (Reshape)   (None, 1, 1, 480)    0           ['block4c_se_squeeze[0][0]']     
                                                                                                  
 block4c_se_reduce (Conv2D)     (None, 1, 1, 20)     9620        ['block4c_se_reshape[0][0]']     
                                                                                                  
 block4c_se_expand (Conv2D)     (None, 1, 1, 480)    10080       ['block4c_se_reduce[0][0]']      
                                                                                                  
 block4c_se_excite (Multiply)   (None, 14, 14, 480)  0           ['block4c_activation[0][0]',     
                                                                  'block4c_se_expand[0][0]']      
                                                                                                  
 block4c_project_conv (Conv2D)  (None, 14, 14, 80)   38400       ['block4c_se_excite[0][0]']      
                                                                                                  
 block4c_project_bn (BatchNorma  (None, 14, 14, 80)  320         ['block4c_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block4c_drop (Dropout)         (None, 14, 14, 80)   0           ['block4c_project_bn[0][0]']     
                                                                                                  
 block4c_add (Add)              (None, 14, 14, 80)   0           ['block4c_drop[0][0]',           
                                                                  'block4b_add[0][0]']            
                                                                                                  
 block5a_expand_conv (Conv2D)   (None, 14, 14, 480)  38400       ['block4c_add[0][0]']            
                                                                                                  
 block5a_expand_bn (BatchNormal  (None, 14, 14, 480)  1920       ['block5a_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block5a_expand_activation (Act  (None, 14, 14, 480)  0          ['block5a_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block5a_dwconv (DepthwiseConv2  (None, 14, 14, 480)  12000      ['block5a_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block5a_bn (BatchNormalization  (None, 14, 14, 480)  1920       ['block5a_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block5a_activation (Activation  (None, 14, 14, 480)  0          ['block5a_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block5a_se_squeeze (GlobalAver  (None, 480)         0           ['block5a_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block5a_se_reshape (Reshape)   (None, 1, 1, 480)    0           ['block5a_se_squeeze[0][0]']     
                                                                                                  
 block5a_se_reduce (Conv2D)     (None, 1, 1, 20)     9620        ['block5a_se_reshape[0][0]']     
                                                                                                  
 block5a_se_expand (Conv2D)     (None, 1, 1, 480)    10080       ['block5a_se_reduce[0][0]']      
                                                                                                  
 block5a_se_excite (Multiply)   (None, 14, 14, 480)  0           ['block5a_activation[0][0]',     
                                                                  'block5a_se_expand[0][0]']      
                                                                                                  
 block5a_project_conv (Conv2D)  (None, 14, 14, 112)  53760       ['block5a_se_excite[0][0]']      
                                                                                                  
 block5a_project_bn (BatchNorma  (None, 14, 14, 112)  448        ['block5a_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block5b_expand_conv (Conv2D)   (None, 14, 14, 672)  75264       ['block5a_project_bn[0][0]']     
                                                                                                  
 block5b_expand_bn (BatchNormal  (None, 14, 14, 672)  2688       ['block5b_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block5b_expand_activation (Act  (None, 14, 14, 672)  0          ['block5b_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block5b_dwconv (DepthwiseConv2  (None, 14, 14, 672)  16800      ['block5b_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block5b_bn (BatchNormalization  (None, 14, 14, 672)  2688       ['block5b_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block5b_activation (Activation  (None, 14, 14, 672)  0          ['block5b_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block5b_se_squeeze (GlobalAver  (None, 672)         0           ['block5b_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block5b_se_reshape (Reshape)   (None, 1, 1, 672)    0           ['block5b_se_squeeze[0][0]']     
                                                                                                  
 block5b_se_reduce (Conv2D)     (None, 1, 1, 28)     18844       ['block5b_se_reshape[0][0]']     
                                                                                                  
 block5b_se_expand (Conv2D)     (None, 1, 1, 672)    19488       ['block5b_se_reduce[0][0]']      
                                                                                                  
 block5b_se_excite (Multiply)   (None, 14, 14, 672)  0           ['block5b_activation[0][0]',     
                                                                  'block5b_se_expand[0][0]']      
                                                                                                  
 block5b_project_conv (Conv2D)  (None, 14, 14, 112)  75264       ['block5b_se_excite[0][0]']      
                                                                                                  
 block5b_project_bn (BatchNorma  (None, 14, 14, 112)  448        ['block5b_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block5b_drop (Dropout)         (None, 14, 14, 112)  0           ['block5b_project_bn[0][0]']     
                                                                                                  
 block5b_add (Add)              (None, 14, 14, 112)  0           ['block5b_drop[0][0]',           
                                                                  'block5a_project_bn[0][0]']     
                                                                                                  
 block5c_expand_conv (Conv2D)   (None, 14, 14, 672)  75264       ['block5b_add[0][0]']            
                                                                                                  
 block5c_expand_bn (BatchNormal  (None, 14, 14, 672)  2688       ['block5c_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block5c_expand_activation (Act  (None, 14, 14, 672)  0          ['block5c_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block5c_dwconv (DepthwiseConv2  (None, 14, 14, 672)  16800      ['block5c_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block5c_bn (BatchNormalization  (None, 14, 14, 672)  2688       ['block5c_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block5c_activation (Activation  (None, 14, 14, 672)  0          ['block5c_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block5c_se_squeeze (GlobalAver  (None, 672)         0           ['block5c_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block5c_se_reshape (Reshape)   (None, 1, 1, 672)    0           ['block5c_se_squeeze[0][0]']     
                                                                                                  
 block5c_se_reduce (Conv2D)     (None, 1, 1, 28)     18844       ['block5c_se_reshape[0][0]']     
                                                                                                  
 block5c_se_expand (Conv2D)     (None, 1, 1, 672)    19488       ['block5c_se_reduce[0][0]']      
                                                                                                  
 block5c_se_excite (Multiply)   (None, 14, 14, 672)  0           ['block5c_activation[0][0]',     
                                                                  'block5c_se_expand[0][0]']      
                                                                                                  
 block5c_project_conv (Conv2D)  (None, 14, 14, 112)  75264       ['block5c_se_excite[0][0]']      
                                                                                                  
 block5c_project_bn (BatchNorma  (None, 14, 14, 112)  448        ['block5c_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block5c_drop (Dropout)         (None, 14, 14, 112)  0           ['block5c_project_bn[0][0]']     
                                                                                                  
 block5c_add (Add)              (None, 14, 14, 112)  0           ['block5c_drop[0][0]',           
                                                                  'block5b_add[0][0]']            
                                                                                                  
 block6a_expand_conv (Conv2D)   (None, 14, 14, 672)  75264       ['block5c_add[0][0]']            
                                                                                                  
 block6a_expand_bn (BatchNormal  (None, 14, 14, 672)  2688       ['block6a_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block6a_expand_activation (Act  (None, 14, 14, 672)  0          ['block6a_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block6a_dwconv_pad (ZeroPaddin  (None, 17, 17, 672)  0          ['block6a_expand_activation[0][0]
 g2D)                                                            ']                               
                                                                                                  
 block6a_dwconv (DepthwiseConv2  (None, 7, 7, 672)   16800       ['block6a_dwconv_pad[0][0]']     
 D)                                                                                               
                                                                                                  
 block6a_bn (BatchNormalization  (None, 7, 7, 672)   2688        ['block6a_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block6a_activation (Activation  (None, 7, 7, 672)   0           ['block6a_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block6a_se_squeeze (GlobalAver  (None, 672)         0           ['block6a_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block6a_se_reshape (Reshape)   (None, 1, 1, 672)    0           ['block6a_se_squeeze[0][0]']     
                                                                                                  
 block6a_se_reduce (Conv2D)     (None, 1, 1, 28)     18844       ['block6a_se_reshape[0][0]']     
                                                                                                  
 block6a_se_expand (Conv2D)     (None, 1, 1, 672)    19488       ['block6a_se_reduce[0][0]']      
                                                                                                  
 block6a_se_excite (Multiply)   (None, 7, 7, 672)    0           ['block6a_activation[0][0]',     
                                                                  'block6a_se_expand[0][0]']      
                                                                                                  
 block6a_project_conv (Conv2D)  (None, 7, 7, 192)    129024      ['block6a_se_excite[0][0]']      
                                                                                                  
 block6a_project_bn (BatchNorma  (None, 7, 7, 192)   768         ['block6a_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block6b_expand_conv (Conv2D)   (None, 7, 7, 1152)   221184      ['block6a_project_bn[0][0]']     
                                                                                                  
 block6b_expand_bn (BatchNormal  (None, 7, 7, 1152)  4608        ['block6b_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block6b_expand_activation (Act  (None, 7, 7, 1152)  0           ['block6b_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block6b_dwconv (DepthwiseConv2  (None, 7, 7, 1152)  28800       ['block6b_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block6b_bn (BatchNormalization  (None, 7, 7, 1152)  4608        ['block6b_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block6b_activation (Activation  (None, 7, 7, 1152)  0           ['block6b_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block6b_se_squeeze (GlobalAver  (None, 1152)        0           ['block6b_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block6b_se_reshape (Reshape)   (None, 1, 1, 1152)   0           ['block6b_se_squeeze[0][0]']     
                                                                                                  
 block6b_se_reduce (Conv2D)     (None, 1, 1, 48)     55344       ['block6b_se_reshape[0][0]']     
                                                                                                  
 block6b_se_expand (Conv2D)     (None, 1, 1, 1152)   56448       ['block6b_se_reduce[0][0]']      
                                                                                                  
 block6b_se_excite (Multiply)   (None, 7, 7, 1152)   0           ['block6b_activation[0][0]',     
                                                                  'block6b_se_expand[0][0]']      
                                                                                                  
 block6b_project_conv (Conv2D)  (None, 7, 7, 192)    221184      ['block6b_se_excite[0][0]']      
                                                                                                  
 block6b_project_bn (BatchNorma  (None, 7, 7, 192)   768         ['block6b_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block6b_drop (Dropout)         (None, 7, 7, 192)    0           ['block6b_project_bn[0][0]']     
                                                                                                  
 block6b_add (Add)              (None, 7, 7, 192)    0           ['block6b_drop[0][0]',           
                                                                  'block6a_project_bn[0][0]']     
                                                                                                  
 block6c_expand_conv (Conv2D)   (None, 7, 7, 1152)   221184      ['block6b_add[0][0]']            
                                                                                                  
 block6c_expand_bn (BatchNormal  (None, 7, 7, 1152)  4608        ['block6c_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block6c_expand_activation (Act  (None, 7, 7, 1152)  0           ['block6c_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block6c_dwconv (DepthwiseConv2  (None, 7, 7, 1152)  28800       ['block6c_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block6c_bn (BatchNormalization  (None, 7, 7, 1152)  4608        ['block6c_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block6c_activation (Activation  (None, 7, 7, 1152)  0           ['block6c_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block6c_se_squeeze (GlobalAver  (None, 1152)        0           ['block6c_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block6c_se_reshape (Reshape)   (None, 1, 1, 1152)   0           ['block6c_se_squeeze[0][0]']     
                                                                                                  
 block6c_se_reduce (Conv2D)     (None, 1, 1, 48)     55344       ['block6c_se_reshape[0][0]']     
                                                                                                  
 block6c_se_expand (Conv2D)     (None, 1, 1, 1152)   56448       ['block6c_se_reduce[0][0]']      
                                                                                                  
 block6c_se_excite (Multiply)   (None, 7, 7, 1152)   0           ['block6c_activation[0][0]',     
                                                                  'block6c_se_expand[0][0]']      
                                                                                                  
 block6c_project_conv (Conv2D)  (None, 7, 7, 192)    221184      ['block6c_se_excite[0][0]']      
                                                                                                  
 block6c_project_bn (BatchNorma  (None, 7, 7, 192)   768         ['block6c_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block6c_drop (Dropout)         (None, 7, 7, 192)    0           ['block6c_project_bn[0][0]']     
                                                                                                  
 block6c_add (Add)              (None, 7, 7, 192)    0           ['block6c_drop[0][0]',           
                                                                  'block6b_add[0][0]']            
                                                                                                  
 block6d_expand_conv (Conv2D)   (None, 7, 7, 1152)   221184      ['block6c_add[0][0]']            
                                                                                                  
 block6d_expand_bn (BatchNormal  (None, 7, 7, 1152)  4608        ['block6d_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block6d_expand_activation (Act  (None, 7, 7, 1152)  0           ['block6d_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block6d_dwconv (DepthwiseConv2  (None, 7, 7, 1152)  28800       ['block6d_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block6d_bn (BatchNormalization  (None, 7, 7, 1152)  4608        ['block6d_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block6d_activation (Activation  (None, 7, 7, 1152)  0           ['block6d_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block6d_se_squeeze (GlobalAver  (None, 1152)        0           ['block6d_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block6d_se_reshape (Reshape)   (None, 1, 1, 1152)   0           ['block6d_se_squeeze[0][0]']     
                                                                                                  
 block6d_se_reduce (Conv2D)     (None, 1, 1, 48)     55344       ['block6d_se_reshape[0][0]']     
                                                                                                  
 block6d_se_expand (Conv2D)     (None, 1, 1, 1152)   56448       ['block6d_se_reduce[0][0]']      
                                                                                                  
 block6d_se_excite (Multiply)   (None, 7, 7, 1152)   0           ['block6d_activation[0][0]',     
                                                                  'block6d_se_expand[0][0]']      
                                                                                                  
 block6d_project_conv (Conv2D)  (None, 7, 7, 192)    221184      ['block6d_se_excite[0][0]']      
                                                                                                  
 block6d_project_bn (BatchNorma  (None, 7, 7, 192)   768         ['block6d_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 block6d_drop (Dropout)         (None, 7, 7, 192)    0           ['block6d_project_bn[0][0]']     
                                                                                                  
 block6d_add (Add)              (None, 7, 7, 192)    0           ['block6d_drop[0][0]',           
                                                                  'block6c_add[0][0]']            
                                                                                                  
 block7a_expand_conv (Conv2D)   (None, 7, 7, 1152)   221184      ['block6d_add[0][0]']            
                                                                                                  
 block7a_expand_bn (BatchNormal  (None, 7, 7, 1152)  4608        ['block7a_expand_conv[0][0]']    
 ization)                                                                                         
                                                                                                  
 block7a_expand_activation (Act  (None, 7, 7, 1152)  0           ['block7a_expand_bn[0][0]']      
 ivation)                                                                                         
                                                                                                  
 block7a_dwconv (DepthwiseConv2  (None, 7, 7, 1152)  10368       ['block7a_expand_activation[0][0]
 D)                                                              ']                               
                                                                                                  
 block7a_bn (BatchNormalization  (None, 7, 7, 1152)  4608        ['block7a_dwconv[0][0]']         
 )                                                                                                
                                                                                                  
 block7a_activation (Activation  (None, 7, 7, 1152)  0           ['block7a_bn[0][0]']             
 )                                                                                                
                                                                                                  
 block7a_se_squeeze (GlobalAver  (None, 1152)        0           ['block7a_activation[0][0]']     
 agePooling2D)                                                                                    
                                                                                                  
 block7a_se_reshape (Reshape)   (None, 1, 1, 1152)   0           ['block7a_se_squeeze[0][0]']     
                                                                                                  
 block7a_se_reduce (Conv2D)     (None, 1, 1, 48)     55344       ['block7a_se_reshape[0][0]']     
                                                                                                  
 block7a_se_expand (Conv2D)     (None, 1, 1, 1152)   56448       ['block7a_se_reduce[0][0]']      
                                                                                                  
 block7a_se_excite (Multiply)   (None, 7, 7, 1152)   0           ['block7a_activation[0][0]',     
                                                                  'block7a_se_expand[0][0]']      
                                                                                                  
 block7a_project_conv (Conv2D)  (None, 7, 7, 320)    368640      ['block7a_se_excite[0][0]']      
                                                                                                  
 block7a_project_bn (BatchNorma  (None, 7, 7, 320)   1280        ['block7a_project_conv[0][0]']   
 lization)                                                                                        
                                                                                                  
 top_conv (Conv2D)              (None, 7, 7, 1280)   409600      ['block7a_project_bn[0][0]']     
                                                                                                  
 top_bn (BatchNormalization)    (None, 7, 7, 1280)   5120        ['top_conv[0][0]']               
                                                                                                  
 top_activation (Activation)    (None, 7, 7, 1280)   0           ['top_bn[0][0]']                 
                                                                                                  
 global_average_pooling2d_5 (Gl  (None, 1280)        0           ['top_activation[0][0]']         
 obalAveragePooling2D)                                                                            
                                                                                                  
 batch_normalization_202 (Batch  (None, 1280)        5120        ['global_average_pooling2d_5[0][0
 Normalization)                                                  ]']                              
                                                                                                  
 dense_30 (Dense)               (None, 512)          655872      ['batch_normalization_202[0][0]']
                                                                                                  
 dropout_12 (Dropout)           (None, 512)          0           ['dense_30[0][0]']               
                                                                                                  
 dense_31 (Dense)               (None, 2)            1026        ['dropout_12[0][0]']             
                                                                                                  
==================================================================================================
Total params: 4,711,589
Trainable params: 1,552,690
Non-trainable params: 3,158,899
__________________________________________________________________________________________________
Epoch 1/100
10/10 [==============================] - 20s 1s/step - loss: 7.9313 - accuracy: 0.6964 - val_loss: 7.7607 - val_accuracy: 0.8218 - lr: 1.0000e-04
Epoch 2/100
10/10 [==============================] - 13s 1s/step - loss: 7.5134 - accuracy: 0.8614 - val_loss: 7.6128 - val_accuracy: 0.8218 - lr: 1.0000e-04
Epoch 3/100
10/10 [==============================] - 11s 1s/step - loss: 7.2971 - accuracy: 0.9076 - val_loss: 7.4827 - val_accuracy: 0.8218 - lr: 1.0000e-04
Epoch 4/100
10/10 [==============================] - 13s 1s/step - loss: 7.1268 - accuracy: 0.9472 - val_loss: 7.3451 - val_accuracy: 0.8416 - lr: 1.0000e-04
Epoch 5/100
10/10 [==============================] - 12s 1s/step - loss: 7.0324 - accuracy: 0.9340 - val_loss: 7.2006 - val_accuracy: 0.8614 - lr: 1.0000e-04
Epoch 6/100
10/10 [==============================] - 11s 1s/step - loss: 6.9017 - accuracy: 0.9439 - val_loss: 7.0648 - val_accuracy: 0.8911 - lr: 1.0000e-04
Epoch 7/100
10/10 [==============================] - 12s 1s/step - loss: 6.7632 - accuracy: 0.9604 - val_loss: 6.9471 - val_accuracy: 0.8713 - lr: 1.0000e-04
Epoch 8/100
10/10 [==============================] - 12s 1s/step - loss: 6.6433 - accuracy: 0.9703 - val_loss: 6.8317 - val_accuracy: 0.8812 - lr: 1.0000e-04
Epoch 9/100
10/10 [==============================] - 13s 1s/step - loss: 6.5118 - accuracy: 0.9802 - val_loss: 6.7130 - val_accuracy: 0.8911 - lr: 1.0000e-04
Epoch 10/100
10/10 [==============================] - 12s 1s/step - loss: 6.4069 - accuracy: 0.9736 - val_loss: 6.5884 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 11/100
10/10 [==============================] - 12s 1s/step - loss: 6.2849 - accuracy: 0.9769 - val_loss: 6.4741 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 12/100
10/10 [==============================] - 13s 1s/step - loss: 6.1680 - accuracy: 0.9868 - val_loss: 6.3617 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 13/100
10/10 [==============================] - 13s 1s/step - loss: 6.0832 - accuracy: 0.9769 - val_loss: 6.2411 - val_accuracy: 0.8911 - lr: 1.0000e-04
Epoch 14/100
10/10 [==============================] - 12s 1s/step - loss: 5.9467 - accuracy: 0.9802 - val_loss: 6.1281 - val_accuracy: 0.8911 - lr: 1.0000e-04
Epoch 15/100
10/10 [==============================] - 11s 1s/step - loss: 5.8393 - accuracy: 0.9835 - val_loss: 6.0261 - val_accuracy: 0.8911 - lr: 1.0000e-04
Epoch 16/100
10/10 [==============================] - 13s 1s/step - loss: 5.7686 - accuracy: 0.9802 - val_loss: 5.9212 - val_accuracy: 0.8911 - lr: 1.0000e-04
Epoch 17/100
10/10 [==============================] - 13s 1s/step - loss: 5.6648 - accuracy: 0.9637 - val_loss: 5.7967 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 18/100
10/10 [==============================] - 12s 1s/step - loss: 5.5327 - accuracy: 0.9802 - val_loss: 5.6858 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 19/100
10/10 [==============================] - 12s 1s/step - loss: 5.4085 - accuracy: 0.9967 - val_loss: 5.5805 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 20/100
10/10 [==============================] - 13s 1s/step - loss: 5.2911 - accuracy: 1.0000 - val_loss: 5.4811 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 21/100
10/10 [==============================] - 13s 1s/step - loss: 5.2099 - accuracy: 0.9868 - val_loss: 5.3824 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 22/100
10/10 [==============================] - 12s 1s/step - loss: 5.1093 - accuracy: 0.9901 - val_loss: 5.2899 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 23/100
10/10 [==============================] - 12s 1s/step - loss: 5.0303 - accuracy: 0.9835 - val_loss: 5.1932 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 24/100
10/10 [==============================] - 12s 1s/step - loss: 4.9276 - accuracy: 0.9802 - val_loss: 5.1011 - val_accuracy: 0.8911 - lr: 1.0000e-04
Epoch 25/100
10/10 [==============================] - 13s 1s/step - loss: 4.8323 - accuracy: 0.9802 - val_loss: 5.0089 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 26/100
10/10 [==============================] - 17s 2s/step - loss: 4.7351 - accuracy: 0.9901 - val_loss: 4.9344 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 27/100
10/10 [==============================] - 14s 1s/step - loss: 4.6379 - accuracy: 0.9967 - val_loss: 4.8817 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 28/100
10/10 [==============================] - 14s 1s/step - loss: 4.5363 - accuracy: 0.9967 - val_loss: 4.8186 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 29/100
10/10 [==============================] - 17s 2s/step - loss: 4.4655 - accuracy: 0.9901 - val_loss: 4.7088 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 30/100
10/10 [==============================] - 28s 3s/step - loss: 4.3659 - accuracy: 0.9901 - val_loss: 4.6181 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 31/100
10/10 [==============================] - 24s 2s/step - loss: 4.2737 - accuracy: 0.9967 - val_loss: 4.5336 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 32/100
10/10 [==============================] - 24s 2s/step - loss: 4.2261 - accuracy: 0.9835 - val_loss: 4.4424 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 33/100
10/10 [==============================] - 19s 2s/step - loss: 4.1369 - accuracy: 0.9802 - val_loss: 4.3496 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 34/100
10/10 [==============================] - 10s 1s/step - loss: 4.0637 - accuracy: 0.9769 - val_loss: 4.2719 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 35/100
10/10 [==============================] - 11s 1s/step - loss: 3.9629 - accuracy: 0.9901 - val_loss: 4.2018 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 36/100
10/10 [==============================] - 12s 1s/step - loss: 3.8813 - accuracy: 0.9934 - val_loss: 4.1336 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 37/100
10/10 [==============================] - 11s 1s/step - loss: 3.8174 - accuracy: 0.9934 - val_loss: 4.0641 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 38/100
10/10 [==============================] - 23s 2s/step - loss: 3.7230 - accuracy: 1.0000 - val_loss: 3.9921 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 39/100
10/10 [==============================] - 28s 3s/step - loss: 3.6560 - accuracy: 0.9934 - val_loss: 3.9229 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 40/100
10/10 [==============================] - 28s 3s/step - loss: 3.5751 - accuracy: 1.0000 - val_loss: 3.8511 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 41/100
10/10 [==============================] - 10s 988ms/step - loss: 3.5315 - accuracy: 0.9835 - val_loss: 3.7813 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 42/100
10/10 [==============================] - 13s 1s/step - loss: 3.4547 - accuracy: 0.9934 - val_loss: 3.7141 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 43/100
10/10 [==============================] - 11s 1s/step - loss: 3.3852 - accuracy: 0.9934 - val_loss: 3.6560 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 44/100
10/10 [==============================] - 11s 1s/step - loss: 3.3321 - accuracy: 0.9868 - val_loss: 3.5930 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 45/100
10/10 [==============================] - 26s 3s/step - loss: 3.2716 - accuracy: 0.9802 - val_loss: 3.5122 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 46/100
10/10 [==============================] - 25s 3s/step - loss: 3.1805 - accuracy: 0.9967 - val_loss: 3.4425 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 47/100
10/10 [==============================] - 24s 2s/step - loss: 3.1274 - accuracy: 0.9901 - val_loss: 3.3758 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 48/100
10/10 [==============================] - 12s 1s/step - loss: 3.0611 - accuracy: 0.9934 - val_loss: 3.3040 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 49/100
10/10 [==============================] - 10s 1s/step - loss: 3.0014 - accuracy: 0.9934 - val_loss: 3.2656 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 50/100
10/10 [==============================] - 11s 1s/step - loss: 2.9490 - accuracy: 0.9934 - val_loss: 3.2365 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 51/100
10/10 [==============================] - 12s 1s/step - loss: 2.8880 - accuracy: 0.9901 - val_loss: 3.2106 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 52/100
10/10 [==============================] - 11s 1s/step - loss: 2.8251 - accuracy: 0.9967 - val_loss: 3.1899 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 53/100
10/10 [==============================] - 19s 2s/step - loss: 2.7884 - accuracy: 0.9901 - val_loss: 3.1477 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 54/100
10/10 [==============================] - 23s 2s/step - loss: 2.7154 - accuracy: 1.0000 - val_loss: 3.0648 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 55/100
10/10 [==============================] - 25s 3s/step - loss: 2.6611 - accuracy: 1.0000 - val_loss: 2.9911 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 56/100
10/10 [==============================] - 13s 1s/step - loss: 2.6052 - accuracy: 0.9967 - val_loss: 2.9232 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 57/100
10/10 [==============================] - 11s 1s/step - loss: 2.5528 - accuracy: 0.9967 - val_loss: 2.8749 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 58/100
10/10 [==============================] - 13s 1s/step - loss: 2.5109 - accuracy: 0.9934 - val_loss: 2.8287 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 59/100
10/10 [==============================] - 12s 1s/step - loss: 2.4606 - accuracy: 0.9967 - val_loss: 2.7723 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 60/100
10/10 [==============================] - 12s 1s/step - loss: 2.4100 - accuracy: 0.9934 - val_loss: 2.7267 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 61/100
10/10 [==============================] - 12s 1s/step - loss: 2.3664 - accuracy: 0.9934 - val_loss: 2.6688 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 62/100
10/10 [==============================] - 13s 1s/step - loss: 2.3245 - accuracy: 0.9901 - val_loss: 2.5992 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 63/100
10/10 [==============================] - 13s 1s/step - loss: 2.2813 - accuracy: 0.9868 - val_loss: 2.5590 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 64/100
10/10 [==============================] - 13s 1s/step - loss: 2.2265 - accuracy: 0.9901 - val_loss: 2.5108 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 65/100
10/10 [==============================] - 13s 1s/step - loss: 2.1878 - accuracy: 0.9967 - val_loss: 2.4500 - val_accuracy: 0.9010 - lr: 1.0000e-04
Epoch 66/100
10/10 [==============================] - 12s 1s/step - loss: 2.1405 - accuracy: 0.9934 - val_loss: 2.4086 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 67/100
10/10 [==============================] - 13s 1s/step - loss: 2.1006 - accuracy: 0.9901 - val_loss: 2.4047 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 68/100
10/10 [==============================] - 13s 1s/step - loss: 2.0628 - accuracy: 0.9901 - val_loss: 2.3554 - val_accuracy: 0.9307 - lr: 1.0000e-04
Epoch 69/100
10/10 [==============================] - 13s 1s/step - loss: 2.0158 - accuracy: 0.9934 - val_loss: 2.3019 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 70/100
10/10 [==============================] - 12s 1s/step - loss: 1.9911 - accuracy: 0.9868 - val_loss: 2.2681 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 71/100
10/10 [==============================] - 11s 1s/step - loss: 1.9415 - accuracy: 0.9934 - val_loss: 2.2089 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 72/100
10/10 [==============================] - 13s 1s/step - loss: 1.8895 - accuracy: 0.9967 - val_loss: 2.1791 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 73/100
10/10 [==============================] - 14s 1s/step - loss: 1.8568 - accuracy: 1.0000 - val_loss: 2.1513 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 74/100
10/10 [==============================] - 12s 1s/step - loss: 1.8261 - accuracy: 0.9967 - val_loss: 2.1177 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 75/100
10/10 [==============================] - 12s 1s/step - loss: 1.7779 - accuracy: 1.0000 - val_loss: 2.0905 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 76/100
10/10 [==============================] - 12s 1s/step - loss: 1.7462 - accuracy: 0.9967 - val_loss: 2.0901 - val_accuracy: 0.9307 - lr: 1.0000e-04
Epoch 77/100
10/10 [==============================] - 14s 1s/step - loss: 1.7123 - accuracy: 1.0000 - val_loss: 2.0718 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 78/100
10/10 [==============================] - 13s 1s/step - loss: 1.6797 - accuracy: 0.9967 - val_loss: 2.0391 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 79/100
10/10 [==============================] - 14s 1s/step - loss: 1.6476 - accuracy: 0.9934 - val_loss: 1.9908 - val_accuracy: 0.9307 - lr: 1.0000e-04
Epoch 80/100
10/10 [==============================] - 13s 1s/step - loss: 1.6141 - accuracy: 0.9967 - val_loss: 1.9383 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 81/100
10/10 [==============================] - 13s 1s/step - loss: 1.5957 - accuracy: 0.9934 - val_loss: 1.9069 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 82/100
10/10 [==============================] - 13s 1s/step - loss: 1.5493 - accuracy: 1.0000 - val_loss: 1.8575 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 83/100
10/10 [==============================] - 13s 1s/step - loss: 1.5290 - accuracy: 0.9934 - val_loss: 1.7990 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 84/100
10/10 [==============================] - 27s 3s/step - loss: 1.4975 - accuracy: 0.9934 - val_loss: 1.7488 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 85/100
10/10 [==============================] - 21s 2s/step - loss: 1.4597 - accuracy: 0.9967 - val_loss: 1.7218 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 86/100
10/10 [==============================] - 19s 2s/step - loss: 1.4438 - accuracy: 0.9967 - val_loss: 1.6972 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 87/100
10/10 [==============================] - 12s 1s/step - loss: 1.4037 - accuracy: 0.9967 - val_loss: 1.6717 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 88/100
10/10 [==============================] - 14s 1s/step - loss: 1.3701 - accuracy: 1.0000 - val_loss: 1.6569 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 89/100
10/10 [==============================] - 27s 3s/step - loss: 1.3422 - accuracy: 1.0000 - val_loss: 1.6400 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 90/100
10/10 [==============================] - 25s 2s/step - loss: 1.3271 - accuracy: 0.9967 - val_loss: 1.6172 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 91/100
10/10 [==============================] - 25s 2s/step - loss: 1.2891 - accuracy: 1.0000 - val_loss: 1.5888 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 92/100
10/10 [==============================] - 20s 2s/step - loss: 1.2834 - accuracy: 0.9868 - val_loss: 1.5662 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 93/100
10/10 [==============================] - 12s 1s/step - loss: 1.2532 - accuracy: 0.9934 - val_loss: 1.5320 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 94/100
10/10 [==============================] - 11s 1s/step - loss: 1.2163 - accuracy: 1.0000 - val_loss: 1.4969 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 95/100
10/10 [==============================] - 13s 1s/step - loss: 1.1982 - accuracy: 0.9934 - val_loss: 1.4842 - val_accuracy: 0.9307 - lr: 1.0000e-04
Epoch 96/100
10/10 [==============================] - 16s 2s/step - loss: 1.1737 - accuracy: 0.9934 - val_loss: 1.4605 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 97/100
10/10 [==============================] - 20s 2s/step - loss: 1.1517 - accuracy: 1.0000 - val_loss: 1.4390 - val_accuracy: 0.9208 - lr: 1.0000e-04
Epoch 98/100
10/10 [==============================] - 22s 2s/step - loss: 1.1224 - accuracy: 1.0000 - val_loss: 1.4173 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 99/100
10/10 [==============================] - 20s 2s/step - loss: 1.1006 - accuracy: 0.9967 - val_loss: 1.4002 - val_accuracy: 0.9109 - lr: 1.0000e-04
Epoch 100/100
10/10 [==============================] - 19s 2s/step - loss: 1.0767 - accuracy: 1.0000 - val_loss: 1.3755 - val_accuracy: 0.9208 - lr: 1.0000e-04
4/4 [==============================] - 7s 1s/step
              precision    recall  f1-score   support

           0       0.92      0.80      0.86        30
           1       0.92      0.97      0.95        71

    accuracy                           0.92       101
   macro avg       0.92      0.89      0.90       101
weighted avg       0.92      0.92      0.92       101



'''